amd/passthrough: Do not leak domain mappings from do_invalidate_dte()
authorAndrew Cooper <andrew.cooper3@citrix.com>
Tue, 10 Dec 2013 15:16:49 +0000 (16:16 +0100)
committerJan Beulich <jbeulich@suse.com>
Tue, 10 Dec 2013 15:16:49 +0000 (16:16 +0100)
commit80dbe90a4e6b31f8cb859f7450fa3eed8695fd1d
tree0f16b3ca46645ecf9939d7c7eed50c52b23dda07
parent552b7fcb9a70f1d4dd0e0cd5fb4d3d9da410104a
amd/passthrough: Do not leak domain mappings from do_invalidate_dte()

Coverity ID: 1135379

As the code stands, the domain mapping will be leaked on each error path.

The mapping can be for a much shorter period of time, and all the relevent
information can be pulled out at once.

Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
Reviewed-by: Jan Beulich <JBeulich@suse.com>
Reviewed-by: Suravee Suthikulpanit <suravee.suthikulpanit@amd.com>
Tested-by: Suravee Suthikulpanit <suravee.suthikulpanit@amd.com>
xen/drivers/passthrough/amd/iommu_guest.c